@using AyBorg.Web.Pages.Agent.Shared.Fields
@using SDK.Common.Ports

@switch (Port.Brand)
{
    case PortBrand.Numeric:
        <NumericInputField Port="Port" ValueChanged="@OnPortValueChangedAsync" Disabled="@Disabled" />
        break;
    case PortBrand.Boolean:
        <BooleanInputField Port="Port" ValueChanged="@OnPortValueChangedAsync" Disabled="@Disabled" />
        break;
    case PortBrand.String:
        <StringInputField Port="Port" ValueChanged="@OnPortValueChangedAsync" Disabled="@Disabled" />
        break;
    case PortBrand.Folder:
        <DirectoryInputField Port="Port" ValueChanged="@OnPortValueChangedAsync" Disabled="@Disabled" />
        break;
    case PortBrand.Image:
        <ImageInputField Port="Port" ShapePorts="_shapePorts" 
                        ValueChanged="@OnPortValueChangedAsync" 
                        Disabled="@Disabled" 
                        OnlyThumbnail="@OnlyThumbnail" />
        break;
    case PortBrand.Rectangle:
        <RectangleInputField Port="Port" ValueChanged="@OnPortValueChangedAsync" Disabled="@Disabled" />
        break;
    case PortBrand.Select:
        <SelectInputField Port="Port" ValueChanged="@OnPortValueChangedAsync" Disabled="@Disabled" />
        break;
    case PortBrand.Enum:
        <EnumInputField Port="Port" ValueChanged="@OnPortValueChangedAsync" Disabled="@Disabled" />
        break;
    case PortBrand.StringCollection:
    case PortBrand.NumericCollection:
    case PortBrand.RectangleCollection:
        <CollectionField Port="Port" ValueChanged="@OnPortValueChangedAsync" Disabled="@Disabled" />
        break;
    default:
        break;
}
